<?php $this->load->view('base/header');?>    

<link href="<?php echo base_url().'uploadify/uploadify.css'?>" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="<?php echo base_url()?>uploadify/swfobject.js"></script>
<script type="text/javascript" src="<?php echo base_url()?>js/page/ajax.js"></script>
<script type="text/javascript" src="<?php echo base_url()?>uploadify/jquery.uploadify.v2.1.4.min.js"></script>
<script type="text/javascript">
    $(document).ready(function() {
        $('#file_upload').uploadify({
            'uploader'  : base_url + 'uploadify/uploadify.swf',
            'script'    : base_url + 'upload/image',
            'cancelImg' : base_url + 'uploadify/cancel.png',
            'folder'    : 'uploads/images/',
            'auto'      : true,
            'onComplete'  : function(event, ID, fileObj, response, data) {
                $("#web_logo").val(fileObj.name);
                $("#view_logo").attr('src', base_url + 'uploads/images/' + fileObj.name);
            }
        });
    });
</script>

<script src="<?php echo base_url()?>js/iphone/iphone-style-checkboxes.js" type="text/javascript" charset="utf-8"></script>
<link rel="stylesheet" href="<?php echo base_url()?>css/iphone/checkbox.css" type="text/css" media="screen" charset="utf-8" />

<script type="text/javascript" charset="utf-8">
    $(window).load(function() {
        $('.:checkbox').iphoneStyle({ checkedLabel: 'Yes         &nbsp;', uncheckedLabel: 'No' });
    });
</script>

<section>
    <div class="container_8 clearfix">
        <!-- Main Section -->
        <section class="main-section grid_8">
            <!-- Sidebar Section -->
            <div class="main-content">
                <header><h2>Settings</h2></header>
                <section class="sidebar-tabbed-pane clearfix">
                    <ul class="sidebar-tabs">
                        <li><a href="#">General</a></li>
                        <li><a href="#">Others</a></li>
                    </ul>
                    <div class="panes">
                        <section>
                            <h3>General</h3>
                            <div style="float: left;">
                                <form id="test_form" class="form" action="<?php echo base_url().'settings/general'?>" method="post">
                                    <div class="clearfix">
                                        <label>Web Name <em>*</em><small>Enter web name that show in dashboard etc</small></label>
                                        <input type="text" id="web_name" name="WEB_NAME" required="required" value="<?php echo $WEB_NAME;?>"/>
                                    </div>
                                    <div class="clearfix">
                                        <label>Web Description <em>*</em><small>Enter web description that match with content</small></label>
                                        <textarea type="text" name="WEB_DESCRIPTION" cols="50" rows="4"><?php echo $WEB_DESCRIPTION;?></textarea>
                                    </div>
                                    <div class="clearfix">
                                        <label>Web Logo<small>Logo Of Site, 150x160 jpeg/png format</small></label>
                                        <div style="padding: 5px 0 0 170px;">
                                            <input type="hidden" id="web_logo" name="WEB_LOGO" value="<?php echo $WEB_LOGO;?>"/>
                                            <input id="file_upload" name="file_upload" type="file" />
                                        </div>
                                    </div>
                                    <div class="clearfix">
                                        <label>In Maintenance<small>System will give announcement that the site is in maintenance</small></label>
                                        <div style="padding: 5px 0 0 170px;">
                                            <?php
                                            if($IS_MAINTENANCE == 0) echo '<input type="checkbox" name="IS_MAINTENANCE"/>';
                                            else echo '<input type="checkbox" checked="checked" name="IS_MAINTENANCE"/>';
                                            ?>
                                        </div>
                                    </div>
                                    <div class="action clearfix">
                                        <button class="button button-gray" type="submit"><span class="accept"></span>OK</button>
                                        <button class="button button-gray" type="reset">Reset</button>
                                    </div>
                                </form>
                            </div>
                            <div style="float: right; max-width: 250px; max-height: 250px;">
                                <fieldset>
                                    <legend>
                                        Preview Web Logo
                                    </legend>
                                    <img id="view_logo" align="center" alt="Web Logo" src="<?php echo base_url().'uploads/images/'.$WEB_LOGO?>"/>
                                </fieldset>
                            </div>
                            <div class="clear"></div>
                        </section>
                        <section>
                            <h3>Others</h3>
                            <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec dignissim eleifend luctus. Fusce vel nunc neque. Fusce pulvinar placerat vestibulum. Praesent scelerisque massa non tellus molestie eu mattis mauris tristique. In urna magna, suscipit ac vestibulum a, lobortis vel enim. Nunc egestas nisi magna. Cras aliquam gravida orci ut semper. Vivamus auctor, nibh id lobortis consequat, augue elit ornare mi, ac aliquet justo odio eu nulla. Nulla ipsum nulla, iaculis nec fringilla blandit, aliquet a sem. Morbi dapibus dolor vitae libero semper sagittis. Ut hendrerit, mi a eleifend consequat, nisi neque blandit quam, nec malesuada turpis velit ac metus. Nullam a pulvinar mi. Sed lobortis sem non metus condimentum fringilla. Fusce vestibulum ultrices sapien, id molestie risus sollicitudin ultricies. Sed scelerisque posuere bibendum. Maecenas luctus, diam eget ultrices rhoncus, est elit scelerisque lectus, quis interdum mi magna in urna. Mauris vitae euismod ligula.</p>
                        </section>
                    </div>
                </section>
            </div>
            <!-- End Sidebar Section -->


        </section>

        <!-- Main Section End -->

    </div>
</section>
</div>

<!-- simple dialog -->
<div class="widget modal" id="simpledialog">
    <header><h2>This is a simple modal dialog</h2></header>
    <section>
        <p>
            Are you sure you want to do this?
        </p>

        <!-- yes/no buttons -->
        <p>
            <button class="button button-blue close">Yes</button>
            <button class="button button-gray close">No</button>
        </p>
    </section>
</div>
<!-- end simple dialog -->

<!--<script>
    $(function () {
        /**
         * Modal Dialog Boxes Setup
         */

        var triggers = $(".modalInput").overlay({

            // some mask tweaks suitable for modal dialogs
            mask: {
                color: '#000',
                loadSpeed: 200,
                opacity: 0.5
            },

            closeOnClick: false
        });

        /* Simple Modal Box */
        var buttons1 = $("#simpledialog button").click(function(e) {

            // get user input
            var yes = buttons1.index(this) === 0;

            if (yes) {
                // do the processing here
            }
        });

    });
</script>-->
<?php $this->load->view('base/footer');?>
